projects
/
gpsbabel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bacdb19
)
Fix 'Invalid free' detected by valgrind.
author
oliskoli
<oliskoli>
Wed, 19 Apr 2006 23:17:55 +0000
(23:17 +0000)
committer
oliskoli
<oliskoli>
Wed, 19 Apr 2006 23:17:55 +0000
(23:17 +0000)
geoniche.c
patch
|
blob
|
history
diff --git
a/geoniche.c
b/geoniche.c
index e5bf8e6aa1ebe60ed5b7834a3f39354407401cb7..8ec4765ed8a2fea040a197f9a2f16e86e8d5902f 100644
(file)
--- a/
geoniche.c
+++ b/
geoniche.c
@@
-630,7
+630,10
@@
geoniche_geostuff(const waypoint *wpt)
xfree(tmp2);
xfree(tmp3);
- return enscape(gs);
+ tmp1 = enscape(gs);
+ xfree(gs);
+
+ return tmp1;
}
static void
@@
-687,10
+690,8
@@
geoniche_writewpt(const waypoint *wpt)
gs = geoniche_geostuff(wpt);
if (gs) {
- char *newnotes = xstrappend(notes, gs);
- xfree (notes);
+ notes = xstrappend(notes, gs);
xfree (gs);
- notes = newnotes;
}
vdata = (ubyte *) xmalloc(vsize);